// pages/HelpStudents/HelpStudents.js
Page({
  data: {
    iphoneXheight: 95,
    currentData: 0,
    index: 0,
    _StudentAssistance: [{
      title: '奖助学金',
      image: '../../../static/image/index/jzxj.png',
      wave: '../../../static/image/index/t_wave.png',
      index: 0,
      background: 'ff4e00'
    }, {
      title: '勤工俭学',
      image: '../../../static/image/index/qgzx.png',
      wave: '../../../static/image/index/t_wave.png',
      index: 1,
      background: '009ffd'
    }, {
      title: '绿色通道',
      image: '../../../static/image/index/lstd.png',
      wave: '../../../static/image/index/t_wave.png',
      index: 2,
      background: '00af43'
    }, {
      title: '助学贷款',
      image: '../../../static/image/index/zxdk.png',
      wave: '../../../static/image/index/t_wave.png',
      index: 3,
      background: '8248ae'
    }]
  },
  onLoad: function(options) {
    if (wx.getSystemInfoSync().model != "iPhone X") {
      this.setData({
        iphoneXheight: 75
      })
    }
  },
  onReady: function() {

  },
  onShow: function() {

  },
  bindchange: function(e) {
    const that = this;
    that.setData({
      currentData: e.detail.current
    })
  },
  currentBind: function(e) {
    const that = this;
    if (that.data.currentData === e.currentTarget.dataset.current) {
      return false;
    } else {
      that.setData({
        currentData: e.currentTarget.dataset.current
      })
    }
  }
})